//
//  FCUserConfigInstance.h
//  FCUserCenter
//
//  Created by mac on 2022/4/2.
//

 
#import <Foundation/Foundation.h>
#import <FCSDK/FCSDK.h>
#import "FCUserDefine.h"
 
NS_ASSUME_NONNULL_BEGIN

#define FCUser_Key_Local_ApnsEnable @"fcuser_local_apnsEnable"
#define FCUser_Key_Local_WifiLookImage @"fcuser_local_wifiLookImage"
#define FCUser_Key_Local_AutoPlayVideo @"fcuser_local_autoPlayVideo"
#define FCUser_Key_Local_NightModel @"fcuser_local_nightModel"
#define FCUser_Key_Local_Font @"fcuser_local_font"


@interface FCUserConfigInstance : FCSDKSingleton<NSCoding>
/**
 返回一个单例
 */
+ (FCUserConfigInstance *)instance;
/**
 一键置灰
 */
@property (nonatomic, assign) BOOL isgray;
/**
 App Store地址
 */
@property (nonatomic, strong) NSString *fc_appUrl;

/*推送开关
 FCDataCacheKey:FCUser_Key_Local_ApnsEnable
 LocalData
 Default:YES
 */
@property (nonatomic, assign) BOOL apnsEnable;

/**
 是否仅在wifi下查看图片
 FCDataCacheKey:FCUser_Key_Local_WifiLookImage
 Default:NO
 */
@property (nonatomic, assign) BOOL wifiLookImage;

/**
 自动播放视频
 FCDataCacheKey:FCUser_Key_Local_AutoPlayVideo
 Default:YES
 */
@property (nonatomic, assign) BOOL autoPlayVideo;


/*夜间模式开关
 FCDataCacheKey:FCUser_Key_Local_NightModel
 LocalData
 Default:NO
 */
@property (nonatomic, assign) BOOL nightModel;



/*正文字体大小
 FCDataCacheKey:FCUser_Key_Local_Font
 LocalData
 Default:FCUser_Config_FontNormal
 */
@property (nonatomic, assign) FCUser_Config_Font font;

//只会统计及清除Document/Caches、Tmp、Caches三个路径下的缓存
- (void)cleanCache:(void(^)(BOOL))result;
//计算本地缓存
- (uint64_t)cacheSize:(void(^)(uint64_t))sizeHander;

/*
根据key，自动判断是否页面模式返回对应颜色
 */
- (unsigned long)corlorByKey:(NSString *)key;

/*
 添加更多颜色进去，key  color相对应
 */
- (void)addColors:(NSDictionary *)corlors isNight:(BOOL)night;

@end

NS_ASSUME_NONNULL_END
